package cn.itcast.feign.client;

import cn.itcast.hmall.pojo.user.Address;
import cn.itcast.hmall.pojo.user.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * 用户服务 feign接口
 * <p>
 * TODO 需要的接口自己补充哦
 */
@FeignClient("userservice")

public interface UserClient {
    @GetMapping("/address/uid")
    public List<Address> selectAddresss();

    @GetMapping("/address/{addressId}")
    public Address selectAddress(@PathVariable("addressId") String id);

    @PostMapping("/address/user")
    public User userselect(@RequestParam Long id);
    @PostMapping("/address/user/je")
    public int updateUserById(@RequestBody User user);

}
